home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 13264 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.8 KB

  1. Path: solon.com!not-for-mail
  2. From: seebs@solutions.solon.com (Peter Seebach)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: Looking for semaphore example.
  5. Date: 5 Apr 1996 12:06:50 -0600
  6. Organization: Usenet Fact Police (Undercover)
  7. Message-ID: <4k3nfq$l94@solutions.solon.com>
  8. References: <4jc5hd$1vlv@ilx018.iil.intel.com> <4jq01e$9kq@solutions.solon.com> <4jro8kINN85c@anvil.ugrad.cs.ubc.ca> <4k1ir3$i4s@sun001.spd.dsccc.com>
  9. Reply-To: seebs@solon.com
  10. NNTP-Posting-Host: solutions.solon.com
  11.  
  12. In article <4k1ir3$i4s@sun001.spd.dsccc.com>,
  13. Mike McCarty <jmccarty@sun1307.spd.dsccc.com> wrote:
  14. >)In article <4jq01e$9kq@solutions.solon.com>,
  15. >)Peter Seebach <seebs@solutions.solon.com> wrote:
  16. >)>Sure.  You could write strictly conforming C which parses and translates
  17. >)>one or more programs in an arbitrary language, and gives them various
  18. >)>"calls" they can make, which could include semaphores.
  19.  
  20. >Such a program might be compliant, but it would not be portable. The
  21. >main reason for compliance is to achieve portability. If one is a priori
  22. >willing to give up portability, then why worry about compliance?
  23.  
  24. Huh?  If it's compliant, it's by definition portable to any machine with a C
  25. compiler.
  26.  
  27. I've written C programs which parse and translate programs in imaginary
  28. languages; it would be easy (a SMOP) to enhance them to run more than one
  29. program at once, and schedule them, and then provide a semaphore-locking
  30. routine.  I could probably provide a dining philosopher language in about
  31. an hour with Lex/Yacc, or a couple of days otherwise.  (I have absolutely no
  32. talent for implementing parsers.)
  33.  
  34. -s
  35. -- 
  36. Peter Seebach - seebs@solon.com - Copyright 1996 Peter Seebach.
  37. C/Unix wizard -- C/Unix questions? Send mail for help.  No, really!
  38. FUCK the communications decency act.  Goddamned government.  [literally.]
  39. The *other* C FAQ - http://www.solon.com/~seebs/c/c-iaq.html
  40.